// @ts-ignore
/* eslint-disable */
import { OpenApi as request } from "@/utils/request";

/** 取验证码 GET /supplier/auth/captcha */
export async function captcha1(options?: { [key: string]: any }) {
  return request<API.BaseResponseSystemCaptchaVo>(
    `/barter-user/supplier/auth/captcha`,
    {
      method: "GET",
      ...(options || {}),
    }
  );
}

/** 供应链认证登录 POST /supplier/auth/login */
export async function login1(
  body: API.LoginValidateDto,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseAuthToken>(
    `/barter-user/supplier/auth/login`,
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    }
  );
}

/** 获取路由 POST /supplier/auth/route */
export async function route1(options?: { [key: string]: any }) {
  return request<API.BaseResponseListMenuVo>(
    `/barter-user/supplier/auth/route`,
    {
      method: "POST",
      ...(options || {}),
    }
  );
}

/** 获取登录用户信息 GET /supplier/auth/userInfo */
export async function userInfo1(options?: { [key: string]: any }) {
  return request<API.BaseResponseSupplierAccountVo>(
    `/barter-user/supplier/auth/userInfo`,
    {
      method: "GET",
      ...(options || {}),
    }
  );
}
